<?php
//Leaps Cache @ 2015-04-07 09:38:41
defined('LEAPS_VERSION') or exit('No permission resources.');
error_reporting ( E_ERROR );
$Head = S('common/common');
$CSS_PATH = SKIN_PATH.'default/css/';
$IMG_PATH = SKIN_PATH.'default/images/';
$JS_PATH = SKIN_PATH.'default/js/';
?>
<?php include template("content","header"); ?>
<!--main-->
<div class="main">
	<div class="col-left channel-hot">
    	<div class="news-hot">
        <div class="icon"></div>
        	<div class="content">
        	<?php if(defined('IN_ADMIN')  && !defined('HTML')) {echo "<div class=\"admin_piao\" yun_action=\"content\" data=\"op=content&tag_md5=c057854ad636b89b9fdbb536fc454a5d&do=position&posid=10&catid=%24catid&thumb=1&order=listorder+DESC&num=2\"><a href=\"javascript:void(0);\" class=\"admin_piao_edit\">编辑</a>";}$content_tag = Loader::lib("content:content_tag");if (method_exists($content_tag, 'position')) {$data = $content_tag->position(array('posid'=>'10','catid'=>$catid,'thumb'=>'1','order'=>'listorder DESC','limit'=>'2',));}?>
				<?php $n=1;if(is_array($data)) foreach($data AS $v) { ?>
				  <h4 class="blue"><a href="<?php echo $v['url'];?>" target="_blank"<?php echo  title_style($v[style]) ;?>><?php echo $v['title'];?></a></h4>
                <p><img src="<?php echo  thumb($v[thumb],90,60) ;?>" width="90" height="60" /><?php echo  str_cut(strip_tags($v[description]), 160) ;?></p>
                <div class="bk20 hr"><hr /></div>
				<?php if(isset($n))$n++;} if(isset($n))unset($n); ?>
			<?php if(defined('IN_ADMIN') && !defined('HTML')) {echo '</div>';}?>
			<?php if(defined('IN_ADMIN')  && !defined('HTML')) {echo "<div class=\"admin_piao\" yun_action=\"content\" data=\"op=content&tag_md5=69ef41840626e8d9e32929532cc6007e&do=lists&catid=%24catid&order=id+DESC&num=3\"><a href=\"javascript:void(0);\" class=\"admin_piao_edit\">编辑</a>";}$content_tag = Loader::lib("content:content_tag");if (method_exists($content_tag, 'lists')) {$data = $content_tag->lists(array('catid'=>$catid,'order'=>'id DESC','limit'=>'3',));}?>
                <ul class="list">
                <?php $n=1; if(is_array($data)) foreach($data AS $k => $v) { ?>
                	<li>·<a href="<?php echo $v['url'];?>" title="<?php echo $v['title'];?>" target="_blank"<?php echo  title_style($v[style]) ;?>><?php echo  str_cut($v[title], 120) ;?></a></li>
                <?php if(isset($n))$n++;} if(isset($n))unset($n); ?>
                </ul>
             <?php if(defined('IN_ADMIN') && !defined('HTML')) {echo '</div>';}?>
            </div>
        </div>
    </div>
    
    
    <div class="col-auto channel-slide">
    <?php if(defined('IN_ADMIN')  && !defined('HTML')) {echo "<div class=\"admin_piao\" yun_action=\"content\" data=\"op=content&tag_md5=ef3a81dc272068bc8a83a0b7f00f69cf&do=lists&catid=%24catid&order=listorder+ASC&thumb=1&num=5\"><a href=\"javascript:void(0);\" class=\"admin_piao_edit\">编辑</a>";}$content_tag = Loader::lib("content:content_tag");if (method_exists($content_tag, 'lists')) {$data = $content_tag->lists(array('catid'=>$catid,'order'=>'listorder ASC','thumb'=>'1','limit'=>'5',));}?>
  		<ul class="thumb">
  		<?php $n=1; if(is_array($data)) foreach($data AS $k => $v) { ?>
        	<li <?php if($n==1) { ?>class="on" style="margin:0"<?php } ?>><a href="<?php echo $v['url'];?>"><img src="<?php echo  thumb($v[thumb], 82, 50) ;?>"  alt="<?php echo $v['title'];?>" width="82" height="50" /><div class="icon"></div></a></li>
        <?php if(isset($n))$n++;} if(isset($n))unset($n); ?>
        </ul>
        <div class="col-auto">
            <ul class="photo">
            <?php $n=1; if(is_array($data)) foreach($data AS $k => $v) { ?>
                <li><a href="<?php echo $v['url'];?>" title="<?php echo $v['title'];?>"><img src="<?php echo  thumb($v[thumb], 398, 234) ;?>" width="398" height="234" alt="<?php echo $v['title'];?>" /></a></li>
            <?php if(isset($n))$n++;} if(isset($n))unset($n); ?>
            </ul>
            <div class="title">
            <?php $n=1; if(is_array($data)) foreach($data AS $k => $v) { ?>
              <p  <?php if($n==1) { ?>style="display:block"<?php } ?>><strong><a href="<?php echo $v['url'];?>" title="<?php echo $v['title'];?>" class="blue"<?php echo  title_style($v[style]) ;?>><?php echo  str_cut($v[title], 36) ;?></a></strong><br /><?php echo  str_cut(strip_tags($v[description]), 62) ;?></p>
            <?php if(isset($n))$n++;} if(isset($n))unset($n); ?>
          </div>
        </div>
         <?php if(defined('IN_ADMIN') && !defined('HTML')) {echo '</div>';}?>
    </div>
   
    <div class="ads">
    	<div class="col-left"><script language="javascript" src="<?php echo defined('SITE_URL') ? SITE_URL : '';?>caches/poster_js/4.js"></script></div>
        <div class="col-auto">
        	<div class="left">推广链接</div>
            <div class="right">这里放广告</div>
        </div>
  </div>
  <div class="bk10"></div>
	<div class="col-left">
	<?php $j=1;?>
	<?php $n=1;if(is_array(subcat($catid))) foreach(subcat($catid) AS $v) { ?>
	<?php if($v['type']!=0) continue;?>
        <div class="box cat-area" <?php if($j%2==1) { ?>style="margin-right:10px"<?php } ?>>
        		<h5 class="title-1"><?php echo $v['catname'];?><a href="<?php echo $v['url'];?>" class="more">更多>></a></h5>
             <div class="content">
             	
				<?php if(defined('IN_ADMIN')  && !defined('HTML')) {echo "<div class=\"admin_piao\" yun_action=\"content\" data=\"op=content&tag_md5=f5bac25e84a0f1fc6ea9cd169b0a9e4b&do=lists&catid=%24v%5Bcatid%5D&thumb=1&num=1&order=id+DESC\"><a href=\"javascript:void(0);\" class=\"admin_piao_edit\">编辑</a>";}$content_tag = Loader::lib("content:content_tag");if (method_exists($content_tag, 'lists')) {$data = $content_tag->lists(array('catid'=>$v[catid],'thumb'=>'1','order'=>'id DESC','limit'=>'1',));}?>
				<p>
					<?php $n=1;if(is_array($data)) foreach($data AS $v) { ?>
						<a href="<?php echo $v['url'];?>" target="_blank"><img src="<?php echo  thumb($v[thumb],70,60) ;?>" width="70" height="60"/></a>
						<strong><a href="<?php echo $v['url'];?>" target="_blank" title="<?php echo $v['title'];?>"<?php echo  title_style($v[style]) ;?>><?php echo  str_cut($v[title], 30) ;?></a></strong><br /><?php echo  str_cut($v[description],116,'..') ;?>
					<?php if(isset($n))$n++;} if(isset($n))unset($n); ?>
					</p>
				<?php if(defined('IN_ADMIN') && !defined('HTML')) {echo '</div>';}?>
                
                <div class="bk15 hr"></div>
                <ul class="list  lh24 f14">
                <?php if(defined('IN_ADMIN')  && !defined('HTML')) {echo "<div class=\"admin_piao\" yun_action=\"content\" data=\"op=content&tag_md5=d38feb5b35b95e2d28d452f9ee745cd6&do=lists&catid=%24v%5Bcatid%5D&num=5&order=id+DESC\"><a href=\"javascript:void(0);\" class=\"admin_piao_edit\">编辑</a>";}$content_tag = Loader::lib("content:content_tag");if (method_exists($content_tag, 'lists')) {$data = $content_tag->lists(array('catid'=>$v[catid],'order'=>'id DESC','limit'=>'5',));}?>
					<?php $n=1;if(is_array($data)) foreach($data AS $v) { ?>
						<li><a href="<?php echo $v['url'];?>" target="_blank"<?php echo  title_style($v[style]) ;?>><?php echo $v['title'];?></a></li>
					<?php if(isset($n))$n++;} if(isset($n))unset($n); ?>
				<?php if(defined('IN_ADMIN') && !defined('HTML')) {echo '</div>';}?>
                </ul>
            </div>
        </div>
        <?php if($j%2==0) { ?><div class="bk10"></div><?php } ?>
	<?php $j++; ?>
	<?php if(isset($n))$n++;} if(isset($n))unset($n); ?>
  </div>
    <div class="col-auto">
        <div class="box">
            <h5 class="title-2">频道总排行</h5>
            <ul class="content digg">
            <?php if(defined('IN_ADMIN')  && !defined('HTML')) {echo "<div class=\"admin_piao\" yun_action=\"content\" data=\"op=content&tag_md5=52a458f88495edbb884953da07c1547f&do=hits&catid=%24catid&num=10&order=views+DESC&cache=3600\"><a href=\"javascript:void(0);\" class=\"admin_piao_edit\">编辑</a>";}$tag_cache_name = md5(implode('&',array('catid'=>$catid,'order'=>'views DESC',)).'52a458f88495edbb884953da07c1547f');if(!$data = S($tag_cache_name)){$content_tag = Loader::lib("content:content_tag");if (method_exists($content_tag, 'hits')) {$data = $content_tag->hits(array('catid'=>$catid,'order'=>'views DESC','limit'=>'10',));}if(!empty($data)){S('tpl_data/'. $tag_cache_name, $data,3600);}}?>
				<?php $n=1;if(is_array($data)) foreach($data AS $v) { ?>
					<li><a href="<?php echo $v['url'];?>" target="_blank"<?php echo  title_style($v[style]) ;?>><?php echo $v['title'];?></a></li>
				<?php if(isset($n))$n++;} if(isset($n))unset($n); ?>
			<?php if(defined('IN_ADMIN') && !defined('HTML')) {echo '</div>';}?>
            </ul>
        </div>
        <div class="bk10"></div>
        <div class="box">
            <h5 class="title-2">频道本月排行</h5>
            <ul class="content rank">
            <?php if(defined('IN_ADMIN')  && !defined('HTML')) {echo "<div class=\"admin_piao\" yun_action=\"content\" data=\"op=content&tag_md5=77dbbbe5d3e062c91a2278b563b02365&do=hits&catid=%24catid&num=8&order=monthviews+DESC&cache=3600\"><a href=\"javascript:void(0);\" class=\"admin_piao_edit\">编辑</a>";}$tag_cache_name = md5(implode('&',array('catid'=>$catid,'order'=>'monthviews DESC',)).'77dbbbe5d3e062c91a2278b563b02365');if(!$data = S($tag_cache_name)){$content_tag = Loader::lib("content:content_tag");if (method_exists($content_tag, 'hits')) {$data = $content_tag->hits(array('catid'=>$catid,'order'=>'monthviews DESC','limit'=>'8',));}if(!empty($data)){S('tpl_data/'. $tag_cache_name, $data,3600);}}?>
				<?php $n=1;if(is_array($data)) foreach($data AS $v) { ?>
				<li><span><?php echo  number_format($v[monthviews]) ;?></span><a href="<?php echo $v['url'];?>"<?php echo  title_style($v[style]) ;?> class="title" title="<?php echo $v['title'];?>"><?php echo  str_cut($v[title],56,'...') ;?></a></li>
				<?php if(isset($n))$n++;} if(isset($n))unset($n); ?>
			<?php if(defined('IN_ADMIN') && !defined('HTML')) {echo '</div>';}?>
            </ul>
        </div>
    </div>
</div>
<script type="text/javascript">
function ChannelSlide(Name,Class){
	$(Name+' ul.photo li').sGallery({
		titleObj:Name+' div.title p',
		thumbObj:Name+' .thumb li',
		thumbNowClass:Class
	});
}
new ChannelSlide(".channel-slide","on",311,260);
</script>
<?php include template("content","footer"); ?>